package tnp.service;
import tnp.dao.ItemMasterDao;
import tnp.model.ItemMasterData;
import com.google.inject.Inject;

public class CommonServiceImpl implements CommonService
{
	@Inject
	private ItemMasterDao itemDao;

	@Override
	public void doLogin()
	{

	}

	@Override
	public void doLogout()
	{

	}

	@Override
	public void entryItem(String itemCode,String item)
	{
		itemDao.insertItemMaster(createItemMaster(itemCode,item));
	}

	private ItemMasterData createItemMaster(String itemCode,String item)
	{
		ItemMasterData ret = new ItemMasterData();
		ret.setItem(item);
		ret.setItemCode(itemCode);
		return ret;
	}
}
